package com.example.service.impl;

import java.util.List;

import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Service;

import com.example.entity.RolesEntity;
import com.example.mapper.RolesMapper;
import com.example.service.RolesService;

@Service
public class RolesServiceImpl implements RolesService{

	@Autowired
	private RolesMapper rolesMapper;
	
	@Override
	public List<RolesEntity> getRoles(Integer userid) {
		// TODO Auto-generated method stub
		return rolesMapper.getRoles(userid);
	}

	@Override
	public List<RolesEntity> find() {
		// TODO Auto-generated method stub
		return rolesMapper.find();
	}

	@Override
	public int addRoles(RolesEntity roles) {
		// TODO Auto-generated method stub
		return rolesMapper.addRoles(roles);
	}

	@Override
	public int upRoles(RolesEntity roles) {
		// TODO Auto-generated method stub
		return rolesMapper.upRoles(roles);
	}

	@Override
	public int delRoles(Integer id) {
		// TODO Auto-generated method stub
		return rolesMapper.delRoles(id);
	}
}
